/**
 * Copyright (c) 快宝网络 kuaidihelp.com Co., Ltd. All Rights Reserved 禁止外泄以及用于其它的商业用途
 */

/**
 * 共配数据监控
 *  */
import React, { useState, useCallback } from "react";
import PageHeaderLayout from "@/layouts/PageHeaderLayout";
import StandardTab from "@/components/StandardTab";
import FormTable from "./FormTable";
import styles from "../style.less";

const DataMonitor = () => {
  const [activeKey, setActiveKey] = useState("scan");

  const onChange = useCallback(_activeKey => {
    setActiveKey(_activeKey);
  }, []);
  return (
    <PageHeaderLayout title="数据监控">
      <div className={styles.main}>
        <StandardTab
          style={{ marginBottom: 24 }}
          onChange={onChange}
          activeKey={activeKey}
          name="dataMonitor"
          panes={[
            {
              tab: "扫描识别记录",
              key: "scan",
              component: <FormTable source="scan" />,
            },
            {
              tab: "特殊件操作记录",
              key: "special",
              component: <FormTable source="special" />,
            },
          ]}
        />
      </div>
    </PageHeaderLayout>
  );
};

export default DataMonitor;
